<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/ViewMasterPage1.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<ComputerShopE3.Models.HOA_DON>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Index</h2>

    <table>
        <tr>
            <th></th>
            
            <% ViewData["HoaDon"] = null; %>
            
           <%--<th>
                id
            </th>--%>
            <th>
                NgayDatHang
            </th>
            <%--<th>
                NgayXacNhan
            </th>--%>
            <th>
                TongTien
            </th>
           <%-- <th>
                TaiKhoanKhachHang
            </th>--%>
            <%--<th>
                GhiChu
            </th>--%>
            <th>
                DonGia
            </th>
            <th>
                TenNguoiNhan
            </th>
            <%--<th>
                DiaChiNguoiNhan
            </th>--%>
            <%--<th>
                SDTNguoiNhan
            </th>--%>
        </tr>

    <% foreach (var item in Model) { %>
    
        <tr>
            <td>
                <%= Html.ActionLink("Edit", "Edit", new { id=item.id }) %> |
                <%= Html.ActionLink("Details", "Details", new { id=item.id })%>
            </td>
            
            <% ViewData["HoaDon"] = item.CHI_TIET_HOA_DON; %>
            
            <%--<td>
                <%= Html.Encode(item.id) %>
            </td>--%>
            <td>
                <%= Html.Encode(String.Format("{0:g}", item.NgayDatHang)) %>
            </td>
            <%--<td>
                <%= Html.Encode(String.Format("{0:g}", item.NgayXacNhan)) %>
            </td>--%>
            <td>
                <%= Html.Encode(item.TongTien) %>
            </td>
            <%--<td>
                <%= Html.Encode(item.TaiKhoanKhachHang) %>
            </td>--%>
            <%--<td>
                <%= Html.Encode(item.GhiChu) %>
            </td>--%>
            <td>
                <%= Html.Encode(item.DonGia) %>
            </td>
            <td>
                <%= Html.Encode(item.TenNguoiNhan) %>
            </td>
            <%--<td>
                <%= Html.Encode(item.DiaChiNguoiNhan) %>
            </td>--%>
           <%-- <td>
                <%= Html.Encode(item.SDTNguoiNhan) %>
            </td>--%>
        </tr>
    
    <% } %>

    </table>

    <p>
        <%= Html.ActionLink("Create New", "Create") %>
    </p>

</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="head" runat="server">
</asp:Content>

<asp:Content ID="Content3" ContentPlaceHolderID="PersonalMenu" runat="server">
</asp:Content>

